package com.wx.wxapp.controller;


import com.wx.wxapp.service.PraiseService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class PraiseController {
    @Autowired
    private PraiseService praiseService;

    @RequestMapping(value = "/praiseFoodCard",method = RequestMethod.POST)
    public void PraiseFoodCard(@RequestParam("cardId")String cardId){
        praiseService.PraiseFoodCard(cardId);
    }

    @RequestMapping(value = "/cancelPraiseFoodCard",method = RequestMethod.POST)
    public void CancelPraiseFoodCard(@RequestParam("cardId")String cardId){
        praiseService.CancelPraiseFoodCard(cardId);
    }

    @RequestMapping(value = "/praiseDiseaseCard",method = RequestMethod.POST)
    public void PraiseDiseaseCard(@RequestParam("cardId")String cardId){
        praiseService.PraiseDiseaseCard(cardId);
    }

    @RequestMapping(value = "/cancelPraiseDiseaseCard",method = RequestMethod.POST)
    public void CancelPraiseDiseaseCard(@RequestParam("cardId")String cardId){
        praiseService.CancelPraiseDiseaseCard(cardId);
    }
}
